iFrame 안에서
function Click1() {
if (parent.postMessage) parent.postMessage(jQuery('body').outerHeight(), "http://parent.co.kr");
}
부모 소스에서
var eventMethod = window.addEventListener ? "addEventListener" : "attachEvent";
var eventer = window[eventMethod];
var messageEvent = eventMethod == "attachEvent" ? "onmessage" : "message";
eventer(messageEvent,function(event) {
console.log('child received message!: ',event.data);
},false);